<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>商品信息维护</title>
    <link rel="stylesheet" href="/style.css">
</head>
<body>
    <div id="navigator">
        <ul id="menu">
            <li onclick="location.href='/merch/findAll'">商品信息维护</li>
            <li onclick="">订单录入</li>
            <li onclick="">订单查询</li>
        </ul>
    </div>

    <div id="main">
        <table>
            <caption>商品信息维护</caption>
            <div id="buttons">
                <input type="button" value="重新查询" onclick="location.href='/index/merch'">
                <input type="button" value="新增商品" onclick="location.href='/merch-add'">
                <input type="button" value="删除" onclick="">
            </div>
            <tr>
                <th>序号</th>
                <th>名称</th>
                <th>代表</th>
                <th>包装</th>
                <th>价格</th>
                <th>生产厂家</th>
            </tr>
            <tr th:each="q:${merchs}">
                <td th:text="${q.id}"></td>
                <td th:text="${q.name}"></td>
                <td th:text="${q.code}"></td>
                <td th:text="${q.packaging}"></td>
                <td th:text="${q.price}"></td>
                <td th:text="${q.factory}"></td>
                <td><a th:href="@{/doDeleteId/{id}(id=${q.id})}">删除</a></td>
            </tr>
        </table>

    </div>
</body>
</html>